/**
 * @author Stéphane LaFlèche <stephane.l@vanillaforums.com>
 * @copyright 2009-2019 Vanilla Forums Inc.
 * @license GPL-2.0-only
 */

@function stripDollarSign($hayStack) {
    $index: str-index($hayStack, "$");

    @if $index and $index == 1 {
        @return str-slice($hayStack, 2, str-length($hayStack));
    }

    @return $hayStack;
}

@mixin sassToCss($varName, $varVal) {
    --#{stripDollarSign($varName)}: $varVal;
}
